﻿// <copyright file="BaseRule.cs" company="Recipe Database">
//     Copyright (c) Recipe Database. All rights reserved.
// </copyright>
// <author>Bjarke Meier</author>
//-----------------------------------------------------------------------

namespace Core.Rules
{
  using Microsoft.FxCop.Sdk;

  /// <summary>
  /// The base class of all rules in namespace Core.Rules.
  /// </summary>
  internal abstract class BaseRule : BaseIntrospectionRule
  {
    // Resource name must be the default namespace of the project + whatever the "RuleMetadata.xml" file is named.
    // TODO: Can we get a static verifiable reference for the resource RuleMetaData.xml instead of the const string?
    
    /// <summary>
    /// Initializes a new instance of the BaseRule class.
    /// </summary>
    /// <param name="ruleName">The name of the (inherited) rule.</param>
    protected BaseRule(string ruleName) : base(ruleName, typeof(BaseRule).Namespace + ".Metadata.xml", Helper.ThisAssembly)
    {
    }
  }
}